<script>
    function arr2json(formArr) {
        var map = {};
        formArr.map(function (value) {
            map[value['name']] = value['value']
        });
        return map;
    }
    function param2url(param){
        var url="";
        for(item in param){
            url+="&"+item+"="+param[item];
        }
        return url;
    }
</script>